package com.study.component;

import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;

import java.time.LocalDateTime;

/**
 * @author zhuzi
 * 2022/8/15 01:14
 */
@Slf4j
@Service
public class TaskComponent {
    @Scheduled(cron = "0/1 * * * * ? ")
    public void deleteFile() {

        log.info("[{}-{}]", Thread.currentThread(), LocalDateTime.now());
    }
}
